package com.example.huaxindemo2.controller;


import com.example.huaxindemo2.entity.M002;
import com.example.huaxindemo2.service.Pr10501Service;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

//Controller层调用Service层，Service层调用Mapper层
@Controller
public class Pr10501Controller {
    @Autowired
    private Pr10501Service pr10501Service;
    @RequestMapping("/pr10501")
    public String pr10501(Model model){
        model.addAttribute("m002", new M002());
        return "/pr10501";
    }

    @RequestMapping("/pr10501_1")
    public String pr10501_1(Model model,Integer m00201){
        pr10501Service.pr10501(model,m00201);
        return "pr10501";
    }
}
